<!doctype html>
<html lang="en">

<head>
	<meta charset="utf-8"/>
	<title>QUẢN TRỊ - AIOSHOP.VN</title>
	
	<link rel="stylesheet" href="css/layout.css" type="text/css" media="screen" />
	<!--[if lt IE 9]>
	<link rel="stylesheet" href="css/ie.css" type="text/css" media="screen" />
	<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
	<![endif]-->
	<script src="js/jquery-1.5.2.min.js" type="text/javascript"></script>
	<script src="js/hideshow.js" type="text/javascript"></script>
	<script src="js/jquery.tablesorter.min.js" type="text/javascript"></script>
	<script type="text/javascript" src="js/jquery.equalHeight.js"></script>
	<script type="text/javascript">
	$(document).ready(function() 
    	{ 
      	  $(".tablesorter").tablesorter(); 
   	 } 
	);
	$(document).ready(function() {

	//When page loads...
	$(".tab_content").hide(); //Hide all content
	$("ul.tabs li:first").addClass("active").show(); //Activate first tab
	$(".tab_content:first").show(); //Show first tab content

	//On Click Event
	$("ul.tabs li").click(function() {

		$("ul.tabs li").removeClass("active"); //Remove any "active" class
		$(this).addClass("active"); //Add "active" class to selected tab
		$(".tab_content").hide(); //Hide all tab content

		var activeTab = $(this).find("a").attr("href"); //Find the href attribute value to identify the active tab + content
		$(activeTab).fadeIn(); //Fade in the active ID content
		return false;
	});

});
    </script>
    <script type="text/javascript">
    $(function(){
        $('.column').equalHeight();
    });
</script>

</head>


<body onload="renderGraph()">

	<header id="header">
		<hgroup>
			<h1 class="site_title"><a href="index.html">AIOSHOP.VN</a></h1>
			<h2 class="section_title">QUẢN TRỊ</h2><div class="btn_view_site"><a href="#">Home</a></div>
		</hgroup>
	</header> <!-- end of header bar -->
	
	<section id="secondary_bar">
		<div class="user">
			<p>Admin (<a href="#">3 Tin nhắn</a>)</p>
			<!-- <a class="logout_user" href="#" title="Logout">Logout</a> -->
		</div>
		<div class="breadcrumbs_container">
			<article class="breadcrumbs"><a href="index.html">Website Admin</a> <div class="breadcrumb_divider"></div> <a class="current">Dashboard</a></article>
		</div>
	</section><!-- end of secondary bar -->
	
	<aside id="sidebar" class="column">
		<form class="quick_search">
			<input type="text" value="Tìm kiếm" onfocus="if(!this._haschanged){this.value=''};this._haschanged=true;">
		</form>
		<hr/>
		<h3>QUẢN LÝ HOA</h3>
		<ul class="toggle">
			<li class="icn_new_article"><a href="#">Thêm Hoa mới</a></li>
			<li class="icn_edit_article"><a href="#">Sửa Hoa</a></li>
			<li class="icn_categories"><a href="#">Quản lý Loại Hoa</a></li>
		</ul>
		<h3>QUẢN LÝ NGƯỜI DÙNG</h3>
		<ul class="toggle">
			<li class="icn_add_user"><a href="#">Thêm người dùng mới</a></li>
			<li class="icn_view_users"><a href="#">Danh sách người dùng</a></li>
			<li class="icn_profile"><a href="#">Thông tin cá nhân</a></li>
		</ul>
		<h3>QUẢN LÝ ĐƠN ĐẶT HÀNG</h3>
		<ul class="toggle">
			<li class="icn_folder"><a href="#">Danh sách đơn đặt hàng</a></li>
			<li class="icn_photo"><a href="#">Danh sách khách hàng</a></li>

		</ul>
		<h3>TÙY CHỌN</h3>
		<ul class="toggle">
			<li class="icn_settings"><a href="#">Cài đặt</a></li>
			<li class="icn_security"><a href="#">Bảo mật</a></li>
			<li class="icn_jump_back"><a href="#">Đăng xuất</a></li>
		</ul>
		
		<footer>
			<hr />
			<p><strong>Copyright &copy; 2011 AIOSHOP.VN</strong></p>
		</footer>
	</aside><!-- end of sidebar -->
	
	<section id="main" class="column">
		
		<h4 class="alert_info">Chào bạn đến với trang quản trị AIOShop</h4>
		
		<article class="module width_full">
			<header><h3>Stats</h3></header>
			<div class="module_content">
				<article class="stats_graph">
				      <div id="googlereport">
            <h1>Google Analytics Report</h1>
            <hr> 
            <button id="authorize-button" style="visibility:hidden">Authorize Analytics</button>
            <hr>
            <div id="ui" style="display:none">
                <h3>Data Over Time</h3>
                <div id='dataOverTimeConfig'></div>

                <h3>Totals for each metric</h3>
                <div id="scorecard"></div>

                <h3>Source and Mediums by Visitor</h3>
                <div id="sourceMediumTableConfig"></div>
               

                    <!-- Load all libraries and run some JS code -->
                    <script src="https://www.google.com/jsapi"></script>
                    <script src="http://analytics-api-samples.googlecode.com/svn/trunk/src/reporting/javascript/ez-ga-dash/gadash-1.0.js"></script>
                    <script src="https://apis.google.com/js/client.js?onload=gadashInit"></script>
                    <script>
        gadash.configKeys({
            'apiKey': 'AIzaSyDwB2RNv3cmWF0qnvAHaqdUUSHcXZgy2nA',
            'clientId': '763622972511.apps.googleusercontent.com'
        });


        // Create new Chart.
        var dataOverTime = new gadash.Chart();
        var scoreCard = new gadash.Chart();
        var sourceMediumTable = new gadash.Chart();


        // Base chart configuration. Used for all charts.
        var baseConfig = {
            'last-n-days': 30,
            'query': {
                'metrics': 'ga:visitors, ga:visits, ga:pageviews',
            },
            'chartOptions': {
                width: 700
            }
        };


        // Configuration for data over time graph.
        var dataOverTimeConfig = {
            'divContainer': 'dataOverTimeConfig',
            'type': 'LineChart',
            'query': {
                'dimensions': 'ga:date',
                'sort': 'ga:date'
            },
            'chartOptions': {
                height: 300,
                legend: {position: 'bottom'},
                hAxis: {title: 'Date'},
                curveType: 'function'
            }
        };


        // Configuration for totals for each metric.
        var scoreCardConfig = {
            'divContainer': 'scorecard',
        };





        /**
         * Handler for the run demo button.
         * Uses the table ID in the form to update the baseConfig object. Then
         * sets baseConfig into each of the charts. Then each chart's specific
         * configuration parameters are set. Finally all are rendered.
         */
        function renderGraph() {
            // Add the table id to the base configuration object.
            baseConfig.query.ids = 'ga:78632249';

            dataOverTime.set(baseConfig).set(dataOverTimeConfig).render();
            scoreCard.set(baseConfig).set(scoreCardConfig).render();


            // Display UI.
            document.getElementById('ui').style.display = 'block';
        }
    </script>
					
					
			</div>
</div>
				</article>

				<div class="clear"></div>
			</div>
		</article><!-- end of stats article -->
		
	
		<div class="spacer"></div>
	</section>


</body>

</html>